package com.example.dell.fastshopping.user.entity;

import java.math.BigDecimal;

/**
 * Created by ${YSH} on 2019/5/9.
 * 描述        ${TODO}
 * <p>
 * 更新者       $author$
 * 更新时间     $Data$
 * 描述         ${TODO}
 */
public class IntegralBaseInformation {
    //integral-积分  price-当前积分价格  status-上涨:1不变:0下跌:-1
    private int integral;
    private BigDecimal price;
    private int status;

    public void setIntegral(int integral) {
        this.integral = integral;
    }

    public void setPrice(BigDecimal price) {
        this.price = price;
    }

    public void setStatus(int status) {
        this.status = status;
    }

    public int getIntegral() {
        return integral;
    }

    public BigDecimal getPrice() {
        return price;
    }

    public int getStatus() {
        return status;
    }

    public String getPriceString() {
        if (price == null) {
            return "";
        }
        String s = price.setScale(2, BigDecimal.ROUND_HALF_UP).toString();
        return "当前积分价格：￥"+s;
    }
}
